clean up some no longer needed logs
authorMatthieu Gallien <matthieu.gallien@nextcloud.com>
Thu, 27 Mar 2025 15:40:07 +0000 (16:40 +0100)
committerMatthieu Gallien <matthieu.gallien@nextcloud.com>
Thu, 10 Apr 2025 12:55:41 +0000 (14:55 +0200)
Signed-off-by: Matthieu Gallien <matthieu.gallien@nextcloud.com>
src/common/checksums.cpp
src/common/syncjournaldb.cpp
src/gui/folderwatcher.cpp
src/libsync/syncengine.cpp

index 5787f2d26dd0926fb76eb3913e0ae6223c15472b..77291d09d3164eeb9ea399ebe72d14ba286b4dc0 100644 (file)
@@ -201,7 +201,7 @@ QByteArray ComputeChecksum::checksumType() const
 
 void ComputeChecksum::start(const QString &filePath)
 {
-    qCInfo(lcChecksums) << "Computing" << checksumType() << "checksum of" << filePath << "in a thread";
+    qCDebug(lcChecksums) << "Computing" << checksumType() << "checksum of" << filePath << "in a thread";
     startImpl(filePath);
 }
 
index 870b22f8bbe830b4287c5db3c54e47977724554e..0813c12a17dc4eb2e0757726dd5c468bd6e65a93 100644 (file)
@@ -1711,13 +1711,11 @@ static void toDownloadInfo(SqlQuery &query, SyncJournalDb::DownloadInfo *res)
     res->_valid = ok;
 }
 
-static bool deleteBatch(SqlQuery &query, const QStringList &entries, const QString &name)
+static bool deleteBatch(SqlQuery &query, const QStringList &entries)
 {
     if (entries.isEmpty())
         return true;
 
-    qCDebug(lcDb) << "Removing stale" << name << "entries:" << entries.join(QStringLiteral(", "));
-    // FIXME: Was ported from execBatch, check if correct!
     for (const auto &entry : entries) {
         query.reset_and_clear_bindings();
         query.bindValue(1, entry);
@@ -1831,7 +1829,7 @@ QVector<SyncJournalDb::DownloadInfo> SyncJournalDb::getAndDeleteStaleDownloadInf
             qCDebug(lcDb) << "database error:" << query->error();
             return empty_result;
         }
-        if (!deleteBatch(*query, superfluousPaths, QStringLiteral("downloadinfo"))) {
+        if (!deleteBatch(*query, superfluousPaths)) {
             return empty_result;
         }
     }
@@ -1965,7 +1963,7 @@ QVector<uint> SyncJournalDb::deleteStaleUploadInfos(const QSet<QString> &keep)
     }
 
     const auto deleteUploadInfoQuery = _queryManager.get(PreparedSqlQueryManager::DeleteUploadInfoQuery);
-    deleteBatch(*deleteUploadInfoQuery, superfluousPaths, QStringLiteral("uploadinfo"));
+    deleteBatch(*deleteUploadInfoQuery, superfluousPaths);
     return ids;
 }
 
@@ -2033,7 +2031,7 @@ bool SyncJournalDb::deleteStaleErrorBlacklistEntries(const QSet<QString> &keep)
 
     SqlQuery delQuery(_db);
     delQuery.prepare("DELETE FROM blacklist WHERE path = ?");
-    return deleteBatch(delQuery, superfluousPaths, QStringLiteral("blacklist"));
+    return deleteBatch(delQuery, superfluousPaths);
 }
 
 void SyncJournalDb::deleteStaleFlagsEntries()
index fc7d05d685a455919f5a8479cf09501f782cdd3b..e8bed199bdef6fb650dd47be1b209c544cfde1a8 100644 (file)
@@ -223,8 +223,6 @@ void FolderWatcher::changeDetected(const QStringList &paths)
             _lockedFiles.insert(checkResult.path);
         }
 
-        qCDebug(lcFolderWatcher) << "Locked files:" << _lockedFiles.values();
-
         // ------- handle ignores:
         if (pathIsIgnored(path)) {
             continue;
@@ -233,9 +231,6 @@ void FolderWatcher::changeDetected(const QStringList &paths)
         changedPaths.insert(path);
     }
 
-    qCDebug(lcFolderWatcher) << "Unlocked files:" << _unlockedFiles.values();
-    qCDebug(lcFolderWatcher) << "Locked files:" << _lockedFiles;
-
     if (!_lockedFiles.isEmpty() || !_unlockedFiles.isEmpty()) {
         if (_lockChangeDebouncingTimer.isActive()) {
             _lockChangeDebouncingTimer.stop();
index 24c86a73b9a0d11f1f6bcf64bb694cde5e611780..9319116312b3b2c91fc5ea93b8a747cf943ac32a 100644 (file)
@@ -228,7 +228,6 @@ void SyncEngine::deleteStaleDownloadInfos(const SyncFileItemVector &syncItems)
         _journal->getAndDeleteStaleDownloadInfos(download_file_paths);
     for (const SyncJournalDb::DownloadInfo &deleted_info : deleted_infos) {
         const QString tmppath = _propagator->fullLocalPath(deleted_info._tmpfile);
-        qCInfo(lcEngine) << "Deleting stale temporary file: " << tmppath;
         FileSystem::remove(tmppath);
     }
 }